{extend name="learun/template/base_main" /}

<!--
  ~ Copyright (c) 2016.  hangzhou BOYE .Co.Ltd. All rights reserved
  -->

{block name="area_header"}
	{notempty name="_menuList" }
	<script type="text/javascript">
		var _menuList = {:json_encode($_menuList)};
	</script>
	{/notempty}
	<link rel="stylesheet" href="__LEARUN__/css/font-awesome.min.css">
	<link rel="stylesheet" href="__LEARUN__/css/index.css">
	<link rel="stylesheet" href="__LEARUN__/css/skins/_all-skins.css">
{/block}

{block name="area_body"}
	<div id="ajax-loader" style="cursor: progress; position: fixed; top: -50%; left: -50%; width: 200%; height: 200%; background: #fff; z-index: 10000; overflow: hidden;">
		<img src="__LEARUN__/img/ajax-loader.gif" style="position: absolute; top: 0; left: 0; right: 0; bottom: 0; margin: auto;" />
	</div>
	<div class="wrapper">
		<!--头部信息-->
		<header class="main-header">
			<a href="{:url('Manager/index')}" target="_self" class="logo">
				<span class="logo-mini">--</span>
				<span class="logo-lg"><strong><em>{:config("UCENTER_PLATFORM")}</em></strong></span>
			</a>
			<nav class="navbar navbar-static-top">
				<a class="sidebar-toggle">
					<span class="sr-only">Toggle navigation</span>
				</a>
				<div class="navbar-custom-menu">
					<ul class="nav navbar-nav">
						<li class="dropdown user user-menu">
							<a href="#" class="dropdown-toggle" data-toggle="dropdown">
								<img src="{:\\app\\src\\admin\\helper\\AdminFunctionHelper::getAvatarUrl($user['id'])}" class="user-image" alt="User Image">
								<span class="hidden-xs">{$user.username}</span>
							</a>
							<ul class="dropdown-menu pull-right">
								<li><a class="menuItem" data-id="clearCache" href="{:url('Account/updatepassword')}"><i class="fa fa-cogs"></i>修改密码</a></li>
								<li><a class="menuItem" data-id="clearCache" href="{:url('Cache/clearAll')}"><i class="fa fa-trash-o"></i>清空缓存</a></li>
								<!--<li><a class="menuItem" data-id="skinSet" href="{:url('Config/set')}"><i class="fa fa-paint-brush"></i>皮肤设置</a></li>-->
								<li class="divider"></li>
								<li><a href="{:url('Index/logout')}"><i class="ace-icon fa fa-power-off"></i>安全退出</a></li>
							</ul>
						</li>
					</ul>
				</div>
			</nav>
		</header>
		<!--左边导航-->
		<div class="main-sidebar">
			<div class="sidebar">
				<ul class="sidebar-menu" id="sidebar-menu">
				</ul>
			</div>
		</div>
		<!--中间内容-->
		<div id="content-wrapper" class="content-wrapper">
			<div class="content-tabs">
				<button class="roll-nav roll-left tabLeft">
					<i class="fa fa-backward"></i>
				</button>
				<nav class="page-tabs menuTabs">
					<div class="page-tabs-content" style="margin-left: 0;">
						<a href="javascript:;" class="menuTab active" data-id="/Default" >欢迎首页</a>
					</div>
				</nav>
				<button class="roll-nav roll-right tabRight">
					<i class="fa fa-forward" style="margin-left: 3px;"></i>
				</button>
				<div class="btn-group roll-nav roll-right">
					<button class="dropdown tabClose" data-toggle="dropdown">
						页签操作<i class="fa fa-caret-down" style="padding-left: 3px;"></i>
					</button>
					<ul class="dropdown-menu dropdown-menu-right">
						<li><a class="tabReload" href="javascript:void(0);">刷新当前</a></li>
						<li><a class="tabCloseCurrent" id="tabCloseCurrent" href="javascript:void(0);">关闭当前(Ctrl+Q)</a></li>
						<li><a class="tabCloseAll" id="tabCloseAll" href="javascript:void(0);">全部关闭(Ctrl+Alt+Q)</a></li>
						<li><a class="tabCloseOther" href="javascript:void(0);">除此之外全部关闭</a></li>
					</ul>
				</div>
				<button class="roll-nav roll-right fullscreen"><i class="fa fa-arrows-alt"></i></button>
			</div>
			<div class="content-iframe" style="overflow: hidden;">
				<div class="mainContent" id="content-main" style="margin: 10px; margin-bottom: 0; padding: 0;">
					<iframe class="LRADMS_iframe" width="100%" height="100%"
							src="{:url('Manager/well')}"
							frameborder="0" data-id="/Default"></iframe>

				</div>
			</div>
		</div>
	</div>
	<script src="__LEARUN__/js/index.js"></script>
{/block}

{block name="area_footer"}
	<script language="JavaScript" type="text/javascript">
		function Hotkey(event, targetObj, ctrlKey, shiftKey, altKey, keycode)
		{
			if (
					targetObj
					&& event.ctrlKey == ctrlKey
					&& event.shiftKey == shiftKey
					&& event.altKey == altKey
					&& event.keyCode == keycode
			)
				targetObj.click();
		}
		function fnKeyup(event)
		{
			var a = document.getElementById("tabCloseAll");
			var c = document.getElementById("tabCloseCurrent");
			Hotkey(event, a, true, false, true,81);
			Hotkey(event, c, true, false, false,81);
		}

		// 捕获系统的Keyup事件
		// 如果是Mozilla系列浏览器
		if (document.addEventListener)
			document.addEventListener("keyup",fnKeyup,true);
		else
			document.attachEvent("onkeyup",fnKeyup);
	</script>
{/block}
